how to add onpressed to a text flutter

107

new GestureDetector(
  onTap: () {
    Navigator.pushNamed(context, "myRoute");
  },
  child: new Text("my Title"),
);

Comments

Submit
0 Comments